---------------------------------  Menu ---------------------------------
local SlobPanel
local SlobList

function CreateSlobBotButton(a, b)
    SLOBBUTTON = vgui.Create("DButton")
    SLOBBUTTON:SetSize(0, 20)
    SLOBBUTTON:SetText(a)
    SLOBBUTTON.DoClick = function()
        RunConsoleCommand(b)
    end
    SlobList:AddItem(SLOBBUTTON)
end


concommand.Add("+wots_menu", function()
    SlobPanel = vgui.Create("DFrame")
	SlobPanel:Center()
    SlobPanel:SetSize(350, 350)
    SlobPanel:SetTitle("SlobBot v0.1")
    SlobPanel:SetVisible(true)
    SlobPanel:SetDraggable(true)
    SlobPanel:ShowCloseButton(false)
	SlobPanel.Paint = function()
		draw.RoundedBox(6, 0, 0, SlobPanel:GetWide(), SlobPanel:GetTall(), Color(176, 226, 255, 225))
		surface.SetDrawColor(color_white)
  		surface.DrawOutlinedRect(0, 0, SlobPanel:GetWide(), SlobPanel:GetTall())
	end
    SlobPanel:MakePopup()


    SlobList = vgui.Create("DPanelList", SlobPanel)
    SlobList:SetPos(30, 30)
    SlobList:SetSize(290, 290)
    SlobList:SetSpacing(5)
    SlobList:SetPadding(5)
    SlobList:EnableHorizontal(false)
    SlobList:EnableVerticalScrollbar(true)


    local AutoAttackCat = vgui.Create("DCheckBoxLabel")
    AutoAttackCat:SetText("Auto attack")
    AutoAttackCat:SetConVar("wots_aimbot_autoattack")
    AutoAttackCat:SetValue(GetConVarNumber("wots_aimbot_autoattack"))
    AutoAttackCat:SizeToContents()
    SlobList:AddItem(AutoAttackCat)


    local MouseLockCat = vgui.Create("DCheckBoxLabel")
    MouseLockCat:SetText("Mouse lock")
    MouseLockCat:SetConVar("wots_aimbot_mouselock")
    MouseLockCat:SetValue(GetConVarNumber("wots_aimbot_mouselock"))
    MouseLockCat:SizeToContents()
    SlobList:AddItem(MouseLockCat)


    local TeamModeCat = vgui.Create("DCheckBoxLabel")
    TeamModeCat:SetText("Team mode")
    TeamModeCat:SetConVar("wots_aimbot_teammode")
    TeamModeCat:SetValue(GetConVarNumber("wots_aimbot_teammode"))
    TeamModeCat:SizeToContents()
    SlobList:AddItem(TeamModeCat)

    local AADelay = vgui.Create("DNumSlider")
    AADelay:SetSize(150, 50)
    AADelay:SetText("Auto attack delay")
    AADelay:SetMin(0)
    AADelay:SetMax(10)
    AADelay:SetDecimals(1)
    AADelay:SetConVar("wots_aimbot_autoattack_delay")
    SlobList:AddItem(AADelay)

    local OFFSET = vgui.Create("DNumSlider")
    OFFSET:SetSize(150, 50)
    OFFSET:SetText("Offset")
    OFFSET:SetMin(-40)
    OFFSET:SetMax(6)
    OFFSET:SetDecimals(0)
    OFFSET:SetConVar("wots_aimbot_add")
    SlobList:AddItem(OFFSET)
	
	local protectBuddys = vgui.Create("DCheckBoxLabel")
	protectBuddys:SetText("Protect players with this nickname:")
	protectBuddys:SetConVar("wots_buddy_attack")
	protectBuddys:SetValue(GetConVarNumber("wots_buddy_attack"))
	protectBuddys:SizeToContents()
	SlobList:AddItem(protectBuddys)
	
	local buddy1 = vgui.Create("DTextEntry")
	buddy1:SetSize(0,20)
	buddy1:SetText("Friend nickname here.")
	buddy1:SetConVar("wots_buddy_1")
	SlobList:AddItem(buddy1)
	
	local buddy2 = vgui.Create("DTextEntry")
	buddy2:SetSize(0,20)
	buddy2:SetText("Friend nickname here.")
	buddy2:SetConVar("wots_buddy_2")
	SlobList:AddItem(buddy2)
	
	local buddy3 = vgui.Create("DTextEntry")
	buddy3:SetSize(0,20)
	buddy3:SetText("Friend nickname here.")
	buddy3:SetConVar("wots_buddy_3")
	SlobList:AddItem(buddy3)
	
	local buddy4 = vgui.Create("DTextEntry")
	buddy4:SetSize(0,20)
	buddy4:SetText("Friend nickname here.")
	buddy4:SetConVar("wots_buddy_4")
	SlobList:AddItem(buddy4)
	
	local buddy5 = vgui.Create("DTextEntry")
	buddy5:SetSize(0,20)
	buddy5:SetText("Friend nickname here.")
	buddy5:SetConVar("wots_buddy_5")
	SlobList:AddItem(buddy5)

    CreateSlobBotButton("ESP", "wots_toggleesp")


    CreateSlobBotButton("WireFrame", "wots_togglewireframe")


    CreateSlobBotButton("DarkRP mode", "wots_togglerphack")


    CreateSlobBotButton("Name changer", "wots_toggleimmunity")

	
	CreateSlobBotButton("NickName List", "wots_nicknamelist")

	
    CreateSlobBotButton("Admin list", "wots_adminlist")
	
	
	CreateSlobBotButton("Megaspam","wots_megaspam")

end)


concommand.Add("-wots_menu", function()
    SlobPanel:Close()
end)

------------------------------------------------------------------------------